# Analysis ID : Certara.R School Lesson 4 - Modeling with RsNLME
# Purpose : Introduce R Markdown
# Other Info :
library(flextable)
library(plotly)
The purpose of this data memo is to provide a summary of the base population pharmacokinetic model fit for study XYZ
dm_table <- readRDS(file='dmtable.RDS')
dm_table
| Characteristic | N = 1501 |
|---|---|
| AGE | 50.5 (38.0 - 61.0) |
| WT | 71 (55 - 94) |
| SEX | |
| F | 45 (30%) |
| M | 105 (70%) |
| RACE | |
| ASIAN | 21 (14%) |
| BLACK | 36 (24%) |
| OTHER | 33 (22%) |
| WHITE | 60 (40%) |
|
1
Mean (Range); n (%)
|
|
mean_conc_table <- readRDS(file='mean_conc_table.RDS')
mean_conc_table
Dose Group | |||
Time (hr) | 5000 μg | 10000 μg | 20000 μg |
0.00 | 0 (0-0) | 0 (0-0) | 0 (0-0) |
0.25 | 19.5 (5.19-56.4) | 38.8 (4.77-111) | 58.3 (6.83-164) |
0.50 | 32.6 (9.88-84.3) | 64.9 (19-167) | 96.9 (27.9-247) |
1.00 | 48.1 (17.2-119) | 96.3 (30.6-235) | 144 (41.1-349) |
2.00 | 56.2 (17.7-116) | 112 (32.7-236) | 169 (51.7-352) |
3.00 | 55.8 (19.8-118) | 112 (37.7-235) | 167 (56-348) |
4.00 | 51.7 (15.4-131) | 103 (27.5-264) | 155 (37.8-400) |
6.00 | 41.2 (9.77-91.4) | 82.4 (14.3-182) | 124 (21.9-270) |
8.00 | 34.7 (9.36-67) | 69.9 (21.7-136) | 104 (29.8-199) |
12.00 | 25 (2.98-69.8) | 49.6 (5.06-140) | 75.8 (8.52-208) |
16.00 | 18.7 (1.08-57.5) | 37.5 (0-115) | 56.8 (0-169) |
24.00 | 9.52 (0.103-32.9) | 19.3 (0-67.3) | 28.1 (0-99.8) |
pkplot <- readRDS(file='pkplot.RDS')
ggplotly(pkplot)
pkplotlog <- readRDS(file='pkplotlog.RDS')
pkplotlog
pkplot_dosesex <- readRDS(file='pkplot_dosesex.RDS')
pkplot_dosesex
pkplot_doserace <- readRDS(file='pkplot_doserace.RDS')
pkplot_doserace
pkplot_dosewt <- readRDS(file='pkplot_dosewt.RDS')
pkplot_dosewt
pkplot_doseage <- readRDS(file='pkplot_doseage.RDS')
pkplot_doseage
Structural PK Model
## View the updated model
basemod<-readRDS("basemod.RDS")
print(basemod)
## Loading required package: Certara.RsNLME
##
## Model Overview
## -------------------------------------------
## Is population : TRUE
## Model Type : PK
##
## PK
## -------------------------------------------
## Parameterization : Clearance
## Absorption : FirstOrder
## Num Compartments : 1
## Dose Tlag? : FALSE
## Elimination Comp ?: FALSE
## Infusion Allowed ?: FALSE
## Sequential : FALSE
## Freeze PK : FALSE
##
## PML
## -------------------------------------------
## test(){
## cfMicro(A1,Cl/V, first = (Aa = Ka))
## dosepoint(Aa)
## C = A1 / V
## error(CEps=5)
## observe(CObs=C + CEps)
## stparm(Ka = tvKa * exp(nKa))
## stparm(V = tvV * exp(nV))
## stparm(Cl = tvCl * exp(nCl))
## fcovariate(AGE)
## fcovariate(WT)
## fcovariate(SEX())
## fcovariate(RACE())
## fcovariate(DOSEGRP)
## fixef( tvKa = c(,1.5,))
## fixef( tvV = c(,80,))
## fixef( tvCl = c(,9,))
## ranef(diag(nKa,nV,nCl) = c(0.1,0.1,0.1))
## }
##
## Structural Parameters
## -------------------------------------------
## Ka V Cl
## -------------------------------------------
## Observations:
## Observation Name : CObs
## Effect Name : C
## Epsilon Name : CEps
## Epsilon Type : Additive
## Epsilon frozen : FALSE
## is BQL : FALSE
## -------------------------------------------
## Column Mappings
## -------------------------------------------
## Model Variable Name : Data Column name
## id : ID
## time : TIME
## Aa : AMT
## AGE : AGE
## WT : WT
## SEX : SEX( M=0 F=1 )
## RACE : RACE( WHITE=0 BLACK=1 ASIAN=2 OTHER=3 )
## DOSEGRP : DOSEGRP
## CObs : CONC
## View the updated model
basemodfit<-readRDS("basemodfit.RDS")
print(basemodfit)
## $Overall
## Scenario RetCode LogLik -2LL AIC BIC nParm nObs nSub
## 1: WorkFlow 1 -7187.912 14375.82 14389.82 14427.68 7 1650 150
## EpsShrinkage Condition
## 1: 0.10699 73.06982
##
## $theta
## #Scenario Parameter Estimate Units Stderr CV% 2.5%CI 97.5%CI
## 1: WorkFlow tvKa 1.195375 NA 0.03937092 3.293605 1.118152 1.272597
## 2: WorkFlow tvV 80.425584 NA 2.83247767 3.521861 74.869937 85.981231
## 3: WorkFlow tvCl 7.731636 NA 0.42486324 5.495127 6.898305 8.564967
## 4: WorkFlow CEps 13.789523 NA 0.77473096 5.618258 12.269959 15.309088
## Var.Inf.factor
## 1: NA
## 2: NA
## 3: NA
## 4: NA
##
## $omega
## Label nKa nV nCl
## 1: nKa 0.07185426 0.0000000 0.0000000
## 2: nV 0.00000000 0.1687598 0.0000000
## 3: nCl 0.00000000 0.0000000 0.3953833
##
## $omega_Correlation
## Label nKa nV nCl
## 1: nKa 1 0 0
## 2: nV 0 1 0
## 3: nCl 0 0 1
##
## $Eta_Shrinkage
## Label nKa nV nCl
## 1: Shrinkage 0.3216746 0.05676357 0.06095907
##
## $omega_stderr
## Label nKa nV nCl
## 1: nKa 0.01546955 0.00000000 0.00000000
## 2: nV 0.00000000 0.02327878 0.00000000
## 3: nCl 0.00000000 0.00000000 0.04707696
sessionInfo()
R version 4.1.2 (2021-11-01)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 10 x64 (build 19044)
Matrix products: default
locale:
[1] LC_COLLATE=English_United States.1252
[2] LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252
[4] LC_NUMERIC=C
[5] LC_TIME=English_United States.1252
attached base packages:
[1] stats graphics grDevices utils datasets methods base
other attached packages:
[1] Certara.RsNLME_1.1.0 plotly_4.10.0 ggplot2_3.3.5
[4] flextable_0.6.10
loaded via a namespace (and not attached):
[1] httr_1.4.2 sass_0.4.0 tidyr_1.2.0
[4] jsonlite_1.8.0 viridisLite_0.4.0 bslib_0.3.1
[7] shiny_1.7.1 assertthat_0.2.1 highr_0.9
[10] yaml_2.3.5 equatags_0.1.1 gdtools_0.2.3
[13] shinymaterial_1.2.0 locatexec_0.1.1 pillar_1.7.0
[16] backports_1.4.0 glue_1.6.2 uuid_1.0-3
[19] digest_0.6.29 polyclip_1.10-0 promises_1.2.0.1
[22] checkmate_2.0.0 colorspace_2.0-3 htmltools_0.5.2
[25] httpuv_1.6.3 pkgconfig_2.0.3 purrr_0.3.4
[28] xtable_1.8-4 scales_1.2.0 xslt_1.4.3
[31] tweenr_1.0.2 later_1.3.0 officer_0.4.1
[34] ggforce_0.3.3 tibble_3.1.6 generics_0.1.2
[37] farver_2.1.0 ellipsis_0.3.2 gtsummary_1.5.0
[40] withr_2.5.0 shinyjs_2.1.0 lazyeval_0.2.2
[43] cli_3.2.0 magrittr_2.0.3 crayon_1.5.1
[46] mime_0.12 evaluate_0.15 fansi_1.0.3
[49] MASS_7.3-54 broom.helpers_1.4.0 xml2_1.3.3
[52] tools_4.1.2 data.table_1.14.2 lifecycle_1.0.1
[55] stringr_1.4.0 munsell_0.5.0 zip_2.2.0
[58] Certara.NLME8_1.2.0 compiler_4.1.2 jquerylib_0.1.4
[61] systemfonts_1.0.3 rlang_1.0.2 grid_4.1.2
[64] gt_0.3.1 rstudioapi_0.13 htmlwidgets_1.5.4
[67] crosstalk_1.2.0 base64enc_0.1-3 labeling_0.4.2
[70] rmarkdown_2.11 gtable_0.3.0 DBI_1.1.1
[73] R6_2.5.1 knitr_1.38 dplyr_1.0.8
[76] fastmap_1.1.0 utf8_1.2.2 commonmark_1.7
[79] stringi_1.7.6 Rcpp_1.0.8.3 vctrs_0.4.1
[82] tidyselect_1.1.2 xfun_0.30